<?php
/**
 * Created by PhpStorm.
 * User: sunshine
 * Date: 2016/9/1
 * Time: 10:21
 */

require_once ('Home/Controller/Controller.php ');
require_once ('Home/Model/StudentModel.php');
class StudentController extends Controller
{
    function __Construct()
    {
        parent::__Construct();
        //$this->mod = 'admin';
        //$this->model=new LoginModel();
        session_start();
        if(!isset($_SESSION['username'])){
            echo '<h2 style="font-family:微软雅黑;color: #03c2f9">您没有登录，请登陆后再访问!<br/></h2>';
            echo '<a href="index.php">如果没有跳转，请点这里跳转</a>';
            header("refresh:3;url='index.php'");
        }
    }
    function student(){
        if(isset($_SESSION['username']))
        $this->display();
    }


}
?>